package com.qf.feign;

import com.qf.pojo.User;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * 兜底类:如果被调用放抛异常 直接返回异常的结果
 * @author lyx
 * @date 2022/7/6 22:13
 */
@Component
@RequestMapping("/searchFallBack")
public class SearcjFeingnFallback  implements SearchFeign{
    @Override
    public String test1() {

        return "fiegn调用出了问题稍后在世";
    }

    @Override
    public User findUserId(Integer id) {
        return new User();
    }
}
